package org.nudt.common.model.vo

import org.nudt.common.model.Video
import java.time.LocalDateTime

data class VideoVO(
    var id: Int?,
    var typeId: Int,
    var videoClass: Int,
    var videoName: String?,
    var coverUrl: String?,
    var coverHUrl: String?,
    var serial: Int?,
    var score: Int?,
    var remarks: String?,
    var updatedAt: LocalDateTime?
) {
    companion object {
        fun of(video: Video): VideoVO {
            return VideoVO(
                video.id,
                video.typeId,
                video.videoClass,
                video.videoName,
                video.coverUrl,
                video.coverHUrl,
                video.serial,
                video.score,
                video.remarks,
                video.updatedAt
            )
        }
    }
}